<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title></title>
    <js file="__PUBLIC__/Js/jquery-1.7.2.min.js"/>
    <js file="__PUBLIC__/Js/ghulam.js"/>
    <css file="__PUBLIC__/Css/public.css"/>

</head>
<body >

<div class="container-fluid" >
    <div class="row">
        <div class="col-sm-9  " style="width: 100%">
            <h3 class="sub-header">编辑友情链接</h3>
            <div class="table-responsive">
                <form action="{:U(GROUP_NAME.'/Link/run_edit')}" id="add-form"  method="post" enctype="multipart/form-data">
                   <foreach name="data" item="v">
                    <table class="table table-striped table-hover">
                        <thead>
                        <tr>
                            <th width="20%">分类</th>
                            <th>参数</th>
                        </tr>
                        </thead>
                        <tbody>
                        <tr>
                            <td>网站名称</td>
                            <td>
                                <input type="text" class="form-control" name="title"  value="{$v.title}"/>
                                <input type="hidden" class="form-control" name="id" value="{$v.id}"/>
                            </td>
                        </tr>
                        <tr>
                            <td>网站网址</td>
                            <td>
                                <input type="text" class="form-control" name="lin_url" value="{$v.lin_url}" />
                            </td>
                        </tr>
                        <tr>
                            <td>网站logo</td>
                            <td >
                                <div style="width: 100px;height: 32px;float: left;"><a href="javascript:;" class="a-upload">网站logo
                                    <input type=file name="lin_img" id="doc" onchange="javascript:setImagePreview();">
                                </a></div>

                                <div style="display: initial; max-width: 200px" id="localImag"></div><div style="max-width: 200px; float: left"><img id="preview" width=-1 height=-1 style="diplay:none" /></div>
                                原图：<img width="130px" height="35px" src="__UPLOAD_LIN_IMG__/{$v.lin_img}"/>

                                <span><input type="hidden" name="lin_old_img" value="{$v.lin_img}"  /></span>

                            </td>
                        </tr>
                        <tr>
                            <td>排序</td>
                            <td>
                                <input type="text" class="form-control" name="lin_sort" value="{$v.lin_sort}" />
                            </td>
                        </tr>
                        <tr>
                            <td></td>
                            <td><input type="submit" id="save" class="btn btn-primary"></td>
                        </tr>
                        </tbody>
                    </table>
                   </foreach>
                </form>
            </div>
        </div>
    </div>
</div>

<link href="__PUBLIC__/bootstrap/css/bootstrap.min.css" rel="stylesheet">
<link href="__PUBLIC__/bootstrap/css/button.css" rel="stylesheet">
<script src="__PUBLIC__/bootstrap/js/jquery-1.9.1.js"></script>
<script src="__PUBLIC__/bootstrap/js/bootstrap.js"></script>
</body>
</html>